<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <title>签署软广合同</title>
    <style>
        body {
            font-family: 'Microsoft YaHei', sans-serif;
            max-width: 800px;
            margin: 40px auto;
            padding: 30px;
            background: #f8f9fa;
        }

        .contract-container {
            background: white;
            padding: 40px;
            border-radius: 12px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
        }

        h2 {
            color: #2d3436;
            margin-bottom: 30px;
            border-bottom: 3px solid #6c5ce7;
            padding-bottom: 12px;
        }

        .alert-message {
            background: #e3f2fd;
            color: #1976d2;
            padding: 14px;
            border-radius: 8px;
            margin-bottom: 25px;
            border-left: 4px solid #6c5ce7;
        }

        .form-group {
            margin-bottom: 24px;
        }

        label {
            display: block;
            margin-bottom: 10px;
            color: #495057;
            font-weight: 600;
        }

        input[type="date"],
        select,
        textarea {
            width: 100%;
            padding: 12px;
            border: 2px solid #e9ecef;
            border-radius: 8px;
            font-size: 16px;
            transition: all 0.3s ease;
        }

        input:focus,
        select:focus,
        textarea:focus {
            border-color: #6c5ce7;
            box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
        }

        button {
            background: #6c5ce7;
            color: white;
            padding: 14px 35px;
            border: none;
            border-radius: 8px;
            font-size: 16px;
            cursor: pointer;
            transition: transform 0.2s, background 0.3s;
        }

        button:hover {
            background: #5b4bc4;
            transform: translateY(-2px);
        }
    </style>
</head>
<body>
    <div class="contract-container">
        <h2>✍️ 签署软广合同</h2>

        {% if message %}
            <div class="alert-message">{{ message }}</div>
        {% endif %}

        <form method="POST">
            {% csrf_token %}
            
            <div class="form-group">
                <label>开始时间</label>
                <input type="date" name="start_time" required>
            </div>

            <div class="form-group">
                <label>结束时间</label>
                <input type="date" name="end_time" required>
            </div>

            <div class="form-group">
                <label>发布媒体</label>
                <select name="media">
                    <option value="抖音">抖音</option>
                    <option value="微博">微博</option>
                    <option value="公众号">公众号</option>
                </select>
            </div>

            <div class="form-group">
                <label>广告需求描述</label>
                <textarea name="need" rows="4" required></textarea>
            </div>

            <div class="form-group" style="margin-top: 30px;">
                <button type="submit">📄 提交合同</button>
            </div>
        </form>
    </div>
</body>
</html>